{% load humanize tz %}

{% if bad_schedule %}
<p id="invalid-arguments">
    Invalid cron expression. <br />
    Please check the <a href="{% url 'hc-docs-cron' %}">supported cron syntax features</a>.

</p>
{% elif bad_tz %}
<p id="invalid-arguments">Invalid timezone.</p>
{% else %}
{% if desc %}<div id="cron-description">“{{ desc }}”</div>{% endif %}
<table id="cron-preview-table" class="table">
    <tr><th id="cron-preview-title" colspan="3">Expected Ping Dates</th></tr>
    {% for d in dates %}
    <tr>
        {% timezone tz %}
        <td>{{ d|date:"M j, H:i" }}</td>
        {% endtimezone %}
        <td>{{ d|naturaltime }}</td>
        <td class="hidden-xs">{{ d|date:"c" }}</td>
    </tr>
    {% endfor %}
</table>
{% endif %}
